<?php echo $header; ?>
<style type="text/css">
#content .blog-post a{
	border-bottom: 1px solid #DFDFDF;
    color: #21759B;
    font-weight: normal;
    text-decoration: none;
}
#content .blog-post a:hover{
	color:#D54E21;
}
#content .blog-post h2{
    font-family: Georgia,Times,"Times New Roman",serif;
    margin: 6px 0;
}
#content .blog-post h2 a{
    font-family: Georgia,Times,"Times New Roman",serif;
    font-weight: 300;
    color: #21759B;
    font-size: 22px;
    text-decoration: none;
    font-style: normal;
    line-height: 22px;
	border-bottom: 0px solid #DFDFDF;
}

#content .meta{
	color: #777777;
    font-size: 12px;
    margin-bottom: 10px;
}    

.storycontent p{
    margin: 0 0 22px;
    padding: 0;
    font-size: 13px;
    color: #444444;
    font-family: sans-serif;
    line-height: 22px;
}
</style>
<?php if (isset($success)) { ?>
<div class="success"><?php echo $success; ?></div>
<?php } ?>
<?php echo $column_left; ?><?php echo $column_right; ?>
<div id="content"><?php echo $content_top; ?>
  <div class="breadcrumb">
    <?php foreach ($breadcrumbs as $breadcrumb) { ?>
    <?php echo $breadcrumb['separator']; ?><a href="<?php echo $breadcrumb['href']; ?>"><?php echo $breadcrumb['text']; ?></a>
    <?php } ?>
  </div>
  <h1><?php echo $heading_title; ?></h1>
  <div class="content">
	  <?php if (isset($posts)) { ?>
	  <div class="product-filter">
		<div class="limit"><b><?php echo $text_limit; ?></b>
		  <select onchange="location = this.value;">
			<?php foreach ($limits as $limits) { ?>
			<?php if ($limits['value'] == $limit) { ?>
			<option value="<?php echo $limits['href']; ?>" selected="selected"><?php echo $limits['text']; ?></option>
			<?php } else { ?>
			<option value="<?php echo $limits['href']; ?>"><?php echo $limits['text']; ?></option>
			<?php } ?>
			<?php } ?>
		  </select>
		</div>
		<div class="sort"><b><?php echo $text_sort; ?></b>
		  <select onchange="location = this.value;">
			<?php foreach ($sorts as $sorts) { ?>
			<?php if ($sorts['value'] == $sort . '-' . $order) { ?>
			<option value="<?php echo $sorts['href']; ?>" selected="selected"><?php echo $sorts['text']; ?></option>
			<?php } else { ?>
			<option value="<?php echo $sorts['href']; ?>"><?php echo $sorts['text']; ?></option>
			<?php } ?>
			<?php } ?>
		  </select>
		</div>
	  </div>
	  
	  
		<?php 
		$i = 1;
		foreach ($posts as $key=>$post) { 
		?>
		<div class="blog-post">
			<div class="pr-heading">
				<h2><a href="<?php echo $post['href'];?>"><?php echo $post['title'];?></a></h2>
				<div class="meta">Posted <?php echo date('F j, Y',strtotime($post['modified']));?> by <?=$post['author_name']?><!-- as  <a rel="category tag" title="View all posts in Events" href="/news/category/events/">Events</a>-->. </div>
			</div>
			<div class="storycontent">
				<p><?php echo $post['description'];?><a href="<?php echo $post['href'];?>">more..</a></p>
			</div> 
		</div>
		<?php } ?>
	 
	  <div class="pagination"><?php echo $pagination; ?></div>
	  <?php } ?>
	  <?php if (!isset($posts)) { ?>
	  <div class="content"><?php echo $text_empty; ?></div>
	  <div class="buttons">
		<div class="right"><a href="<?php echo $continue; ?>" class="button"><span><?php echo $button_continue; ?></span></a></div>
	  </div>
	  <?php } ?>
  </div>

  <?php echo $content_bottom; ?></div>
<?php echo $footer; ?> 